-- GENERATED SPELL FOR [Greyheart Spellbinder] --


function spell0_21806(pUnit, Event) --@Mind Blast,n/a--
pUnit:FullCastSpellOnTarget(37531,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_21806', 1500, 1)
end

function spell1_21806(pUnit, Event) --@Spell Shock,n/a--
pUnit:FullCastSpellOnTarget(39076,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_21806', 6288, 1)
end

function Sorts_21806(pUnit, Event)
local choix_sorts_21806 = math.random(0, 1)
if choix_sorts_21806 == 0 then
pUnit:RegisterEvent('spell0_21806', 1, 1)
end
if choix_sorts_21806 == 1 then
pUnit:RegisterEvent('spell1_21806', 1, 1)
end
end

function mob21806_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_21806', math.random(1500, 3000), 1)
end

function mob21806_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob21806_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob21806_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(21806, 1, 'mob21806_Action')
RegisterUnitEvent(21806, 2, 'mob21806_Leave')
RegisterUnitEvent(21806, 3, 'mob21806_Kill')
RegisterUnitEvent(21806, 4, 'mob21806_Die')
